home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 002 / chedit.arc / REPLACEP.BUG < prev    next >
Text File  |  1986-07-23  |  3KB  |  52 lines

  1. {
  2.    This program is placed in the public domain by its author, William Couture.
  3.    Copyright (c) 1986 by DDI.    All Rights Reserved.
  4. }
  5.  
  6. procedure grchar(whichchar,color:integer);
  7.                { NOTE: whichchar is 0..127 OR 128..255
  8.                        color is 0..3 in 320x200 mode, 0..1 in 640x200 mode }
  9.    begin
  10.       if color = 0 then
  11.                { The character used to erase the screen is the space from
  12.                  the regular character set.  If you wish to use a different
  13.                  character, change the sequence $b0/$20 to $b0/$?? where ??
  14.                  is the hex code of the character to be used ($00..$7f for
  15.                  regular characters, $80..$ff for graphics characters) }
  16.          inline($b4/$09/$b0/$20/$b3/$01/$b9/$01/$00/$55/$cd/$10/$5d)
  17.       else
  18.                { Currently, this routine always turns on the high bit, making
  19.                  the character a graphics character.  If you wish to use
  20.                  0..127 as graphics characters and 128..255 as the regular
  21.                  characters, change the $0c after the <whichchar to a $04
  22.                  i.e. <whichchar/$0c becomes <whichchar/$04 }
  23.          inline($b4/$09/$8a/$46/<whichchar/$0c/$80/$8a/$5e/<color/$b9/
  24.                 $01/$00/$55/$cd/$10/$5d);
  25.    end;
  26.  
  27. procedure gratchar(row,col,whichchar,color:integer);
  28.                { NOTE: whichchar is 0..127 OR 128..255
  29.                        row is 1..25
  30.                        col is 1..40 in 320x200 mode, 1..80 in 640x200 mode
  31.                        color is 0..3 in 320x200 mode, 0..1 in 640x200 mode }
  32.    begin
  33.       if color = 0 then
  34.                { The character used to erase the screen is the space from
  35.                  the regular character set.  If you wish to use a different
  36.                  character, change the sequence $b0/$20 to $b0/$?? where ??
  37.                  is the hex code of the character to be used ($00..$7f for
  38.                  regular characters, $80..$ff for graphics characters) }
  39.          inline($b4/$02/$8a/$76/<row/$fe/$ce/$8a/$56/<col/$fe/$ca/$b7/$00/
  40.                 $55/$cd/$10/$5d/$b4/$09/$b0/$20/$b3/$01/$b9/$01/$00/$55/
  41.                 $cd/$10/$5d)
  42.       else
  43.                { Currently, this routine always turns on the high bit, making
  44.                  the character a graphics character.  If you wish to use
  45.                  0..127 as graphics characters and 128..255 as the regular
  46.                  characters, change the $0c after the <whichchar to a $04
  47.                  i.e. <whichchar/$0c becomes <whichchar/$04 }
  48.          inline($b4/$02/$8a/$76/<row/$fe/$ce/$8a/$56/<col/$fe/$ca/$b7/$00/
  49.                 $55/$cd/$10/$5d/$b4/$09/$8a/$46/<whichchar/$0c/$80/$8a/$5e/
  50.                 <color/$b9/$01/$00/$55/$cd/$10/$5d);
  51.    end;
  52.